//
//  QMUIConfigurationTemplate.m
//  qmui
//
//  Created by QMUI Team on 15/3/29.
//  Copyright (c) 2015年 QMUI Team. All rights reserved.
//

#import "QMUIConfigurationTemplateDark.h"

@implementation QMUIConfigurationTemplateDark

#pragma mark - <QMUIConfigurationTemplateProtocol>

- (void)applyConfigurationTemplate {
    [super applyConfigurationTemplate];
    
    QMUICMI.keyboardAppearance = UIKeyboardAppearanceDark;
    
    QMUICMI.navBarBackgroundImage = nil;
    QMUICMI.navBarStyle = UIBarStyleBlack;
    
    QMUICMI.tabBarBackgroundImage = nil;
    QMUICMI.tabBarStyle = UIBarStyleBlack;
    
    QMUICMI.toolBarStyle = UIBarStyleBlack;
}

// QMUI 2.3.0 版本里，配置表新增这个方法，返回 YES 表示在 App 启动时要自动应用这份配置表。仅当你的 App 里存在多份配置表时，才需要把除默认配置表之外的其他配置表的返回值改为 NO。
- (BOOL)shouldApplyTemplateAutomatically {
    [QMUIThemeManagerCenter.defaultThemeManager addThemeIdentifier:self.themeName theme:self];
    
    NSString *selectedThemeIdentifier = [[NSUserDefaults standardUserDefaults] stringForKey:QDSelectedThemeIdentifier];
    BOOL result = [selectedThemeIdentifier isEqualToString:self.themeName];
    if (result) {
        QMUIThemeManagerCenter.defaultThemeManager.currentTheme = self;
    }
    return result;
}

#pragma mark - <QDThemeProtocol>

- (UIColor *)themeBackgroundColor {
    return UIColorDarkBlack1;
}

- (UIColor *)themeBackgroundColor2 {
    return UIColorDarkBlack2;
}

- (UIColor *)themeBackgroundColor3 {
    return UIColorDarkBlack3;
}

- (UIColor *)themeTFBackgroundColor2 {
    return UIColorDarkBlack2;
}

- (UIColor *)themeTFBackgroundColor3 {
    return UIColorDarkBlack3;
}

- (UIColor *)themeLineColor {
    return UIColorDarkLine1;
}
- (UIColor *)themeLineColor2 {
    return UIColorDarkLine2;
}
- (UIColor *)themeLineColor3 {
    return UIColorDarkLine3;
}
- (UIColor *)themeLineColor4 {
    return UIColorText5;
}

- (UIColor *)themeBackgroundColorLighten {
    //#F2F5FA
    return UIColorDarkBlack1;
}
- (UIColor *)themeBackgroundColorLighten2 {
    //#F2F5FA
    return UIColorDarkBlack2;
}
- (UIColor *)themeBackgroundColorLighten3 {
    //#F2F5FA
    return UIColorDarkBlack3;
}
- (UIColor *)themeBackgroundColorLighten4 {
    //#F2F5FA
    return UIColorDarkBlack3;
}

// F5F5F7
- (UIColor *)themeBackgroundColorLighten5 {
    return  UIColorDarkBlack2;;
}
- (UIColor *)themeBackgroundColorLighten6 {
    return  UIColorDarkBlack2;
}

- (UIColor *)themeBackgroundColorHighlighted {
    return UIColorMake(56, 57, 58);
}

- (UIColor *)themeTitleTextColor {
    return UIColorWhite;
}

- (UIColor *)themeMainTextColor {
    return UIColorWhite;
}

- (UIColor *)themeTitleTextColor2 {
    return UIColorMake(153,153,153);
}

- (UIColor *)themeMainTextColor2 {
    return UIColorMake(153,153,153);
}

- (UIColor *)themeDescriptionTextColor {
    return UIColorMake(153,153,153);
}

- (UIColor *)themePlaceholderColor {
    return UIColorDarkGray8;
}

- (UIColor *)themeInfoTitleColor {
    return UIColorMake(153,153,153);
}

- (UIColor *)themeCodeColor {
    return self.themeTintColor;
}

- (UIColor *)themeSeparatorColor {
    return UIColorMake(46, 50, 54);
}

- (NSString *)themeName {
    return QDThemeIdentifierDark;
}


- (UIColor *)themeTintColor {
    return UIColorMake(79, 128, 255);
}

- (UIColor *)themeColor2 {
    return UIColorMake(255, 143, 0);
}
- (UIColor *)themeColor3 {
    return UIColorMake(79, 128, 255);
}
- (UIColor *)themeColor4 {
    return UIColorMake(83,182,249);
}
- (UIColor *)themeColor5 {
    return UIColorMake(246,201,130);
}
- (UIColor *)themeColor6 {
    return UIColorMake(150,202,136);
}
- (UIColor *)themeColor7 {
    return UIColorMake(79,128,255);
}
- (UIColor *)themeColor8 {
    return UIColorMake(235,35,0);
}
- (UIColor *)themeColor9 {
    return UIColorMake(253,88,73);
}
- (UIColor *)themeColor10 {
    return UIColorMake(0,217,89);
}
- (UIColor *)themeColor11 {
    return UIColorMake(0,0,0);
}
- (UIColor *)themeColor12 {
    return UIColorMake(35,100,225);
}
- (UIColor *)themeColor13 {
    return UIColorMake(60,144,255);
}
- (UIColor *)themeColor14 {
    return UIColorMake(255,104,31);
}
- (UIColor *)themeColor15 {
    return UIColorMake(25,188,156);
}
- (UIColor *)themeColor16 {
    return UIColorMake(62,223,130);
}
- (UIColor *)themeColor17 {
    return UIColorMake(79,128,255);
}
- (UIColor *)themeColor24 {
    return UIColorMake(79, 128, 255);
}

- (UIColor *)themeColor25 {
    return UIColorMake(255, 143, 0);
}

- (UIColor *)themeAuxiliaryColor1 {
    return UIColorMake(238, 135, 113);
}

- (UIColor *)themeAuxiliaryColor2 {
    return UIColorMakeWithHex(@"#4F80FF");
}

- (UIColor *)themeAuxiliaryColor3 {
    return UIColorMakeWithHex(@"#00D959");
}

- (UIColor *)themeAuxiliaryColor4 {
    return UIColorMakeWithHex(@"#FFAF10");
}

- (UIColor *)themeAuxiliaryColor5 {
    return UIColorMakeWithRGBA(255, 96, 90, 1);
}

- (UIColor *)themeRentProgressLBBackColor {
    return UIColorMake(79, 128, 255);
}

- (UIColor *)themeRentProgressLBTitleColor {
    return UIColorWhite;
}

- (UIColor *)themeRewardBuyTitleColor {
    return UIColorMakeWithRGBA(255, 89, 146, 1);
}
- (UIColor *)themeRewardBuyCountBGColor {
    return UIColorMake(255, 69, 146);
}
- (UIColor *)themeRewardRedeemTitleColor {
    return UIColorMakeWithRGBA(0, 185, 255, 1);
}
- (UIColor *)themeRewardDeleteTitleColor {
    return UIColorMakeWithRGBA(255, 255, 255, 0.6);
}
- (UIColor *)themeMenuShadowColor {
    return UIColorMake(42, 42, 49);
}

- (UIColor *)themeHomeNameColor {
    return UIColorMake(153, 153, 153);
}

- (UIColor *)themeEmptyTextColor {
    return UIColorMake(153, 153, 153);
}
#pragma mark - COLOR ↑ --


- (UIImage *)themeMenuTopImage {
    return UIImageMake(@"menu_besselcurve3");
}

- (UIImage *)themeMenuTopMask {
    return UIImageMake(@"menu_mask3");
}

- (UIImage *)themeSuccessImage {
    return UIImageMake(@"wallet_refundSucc3");
}

- (UIImage *)themeRentingBallImage {
    return UIImageMake(@"renting_ballon3");
}

- (UIImage *)themeArrowTick {
    return UIImageMake(@"arrow_tick3");
}

- (UIImage *)themeFeedbackSelImg {
    return UIImageMake(@"report_selected3");
}

- (UIImage *)themeFeedbackUnSelImg {
    return UIImageMake(@"report_unselected3");
}

- (UIImage *)themeFeedbackSignSelImg {
    return UIImageMake(@"report_selectedSingle3");
}

- (UIImage *)themeFeedbackSignUnSelImg {
    return UIImageMake(@"report_unselectedSingle3");
}

- (UIImage *)themeAddCardUnSelImg {
    return UIImageMake(@"payment_unsucc3");
}
- (UIImage *)themeAddCardSelImg {
    return UIImageMake(@"payment_succSel3");
}
- (UIImage *)themeCardDefaultImg {
    return UIImageMake(@"card_select443");
}
- (UIImage *)themeCardCloseImg {
    return UIImageMake(@"arrow_close_gray443");
}

- (UIImage *)themeRewardPointImg {
    return UIImageMake(@"rewards_typePoint2");
}
- (UIImage *)themeRewardPointLineImg {
    return UIImageMake(@"rewards_pointLine2");
}

- (UIImage *)themeRewardLocationImg1 {
    return UIImageMake(@"rewards_typeLocations2");
}
- (UIImage *)themeRewardLocationImg2 {
    return UIImageMake(@"rewards_typeLocationsAlpha2");
}
- (UIImage *)themeRewardCalenderImg1 {
    return UIImageMake(@"rewards_calendar2");
}
- (UIImage *)themeRewardCalenderImg2 {
    return UIImageMake(@"rewards_calendarAlpha2");
}
- (UIImage *)themeRewardMoneyImg {
    return UIImageMake(@"rewards_typeMoney2");
}
- (UIImage *)themeRewardNextImg {
    return UIImageMake(@"arrow_right_white6");
}
- (UIImage *)themeInviteMoreImg {
    return UIImageMake(@"arrow_dRight_blue6");
}
- (UIImage *)themeInviteCopyImg {
    return UIImageMake(@"rewards_copy2");
}

- (UIImage *)themeHomeLocImg {
    return UIImageMake(@"home_shop2");
}
- (UIImage *)themeHomeLocBigImg {
    return UIImageMake(@"home_shopSel2");
}

- (UIImage *)themeCouponMoreImg {
    return UIImageMake(@"coupon_more2");
}

- (UIImage *)themeMenuLogoImg {
    return UIImageMake(@"menu_profile2");
}

- (UIImage *)themeStationDefaultImg {
    return UIImageMake(@"pic_station");
}

- (UIImage *)themeWalletWarningImg {
    return UIImageMake(@"wallet_refundedWarning2");
}

- (UIImage *)themeRewardPointTopImg {
    return UIImageMake(@"rewards_point2");
}

- (UIImage *)themeHomeMenuImg {
    return UIImageMake(@"home_menuWhite");
}

- (UIImage *)themeHomeScanImg {
    return UIImageMake(@"home_sacnMask1");
}

- (UIImage *)themeHomeLocationImg {
    return UIImageMake(@"home_ic_focus1");
}

- (UIImage *)themeHomeMapOpenImg {
    return UIImageMake(@"home_zoom1");
}

- (UIImage *)themeHomeMapCloseImg {
    return UIImageMake(@"home_reduce1");
}

- (UIImage *)themeHomeShadowImg {
    CGFloat view_h = kScale414(168 + kSafeAreaTopHeight);
    return [BRTools gradientHomesShadowImageWithColors:[BRThemeManage br_homeMapShadowColors] rect:CGRectMake(0, 0, kScreenWidth, view_h)];
}

@end
